package com.yc.cloud.cloudindex.web;

import com.yc.cloud.cloudindex.RunProperties;
import org.springframework.cloud.context.config.annotation.RefreshScope;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;

@RestController
@RefreshScope  // 定义刷新参数的作用域
public class PropsAction {
    @Resource
    private RunProperties properties;

    @RequestMapping("show")
    public RunProperties show(){
        return properties;
    }
}
